import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
import path from "path";

// https://vitejs.dev/config/
export default defineConfig({
  plugins: [vue()],
  build: {
    outDir: "dist",
    lib: {
      entry: path.resolve(__dirname, "./src/components/index.js"),
      name: "pass-ui",
      fileName: "paas-ui",
    },
    rollupOptions: {
      external: ["vue", "heyui"],
      output: {
        globals: {
          vue: "Vue",
          heyui: "heyui"
        },
      },
    },
  },
})
